import { _decorator, Component, game } from "cc";
const { ccclass } = _decorator;

@ccclass("PersistNode")
export class PersistNode extends Component {

    public onLoad(): void {
        game.addPersistRootNode(this.node);
    }

}